package com.hist.config;

import com.hist.pojo.User;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;

/**
 * @auther Ren Gaoshuai
 * @date 2021-04-06 13:56
 **/
@Configuration  //这是一个配置类
@ComponentScan("com.hist.pojo")     //配置要扫描注解的包
public class UserConfig {

    @Bean   //声明一个bean
    public User getUser(){
        return new User();
    }
}
